<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<!-- 分页模块 -->
<th:block th:fragment="page">
    <div class="layui-row" th:if="${#pageUtil2.pageInit(page,#request)}">
        <div class="layui-col-sm6">
            <div class="page-info">
                <span>显示 [[${((page.pageNum-1)*page.pageSize)+1}]]/[[${(page.pageNum*page.pageSize)}]] 条，共 [[${page.total}]] 条记录</span>
                <select class="timo-select page-number" name="pageSize">
                    <option th:value="${pageNum}"  th:selected="${page.pageSize} eq ${pageNum*10}" th:each="pageNum:${#numbers.sequence(1,6)}">[[${pageNum*10}]] 条/页</option>
                </select>
            </div>
        </div>
        <div class="layui-col-sm6">
            <ul class="pagination list-page">
                <li class="page-item" th:if="${#pageUtil2.isPrevious(page)}">
                    <a class="page-link prpr" th:href="@{${#pageUtil2.pageHref(page.pageNum-1)}}">上一页</a>
                </li>
                <li th:each="pageCode:${#pageUtil2.pageCode(page)}" th:class="'page-item'+ ${#pageUtil2.pageActive(page, pageCode, 'active')}">
                    <a class="page-link pnpn" th:if="${#pageUtil2.isCode(pageCode)} ne true" th:href="@{${#pageUtil2.pageHref(pageCode)}}">[[${pageCode}]]</a>
                    <a class="page-link breviary" th:if="${#pageUtil2.isCode(pageCode)}">…</a>
                </li>
                <li class="page-item" th:if="${#pageUtil2.isNext(page)}">
                    <a class="page-link" th:href="@{${#pageUtil2.pageHref(page.pageNum+2)}}">下一页</a>
                </li>
            </ul>
        </div>
    </div>
</th:block>
